package rsee.com;

import com.video.h264.GlobalUtil;

import ezeye.device.EyeDeviceInfo;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;
import android.widget.Button;
import android.widget.RelativeLayout;

public class RemoteConfigP  extends Activity
{     private RelativeLayout relativeLayout1 ,relativeLayout2,relativeLayout3;
      private     String current = null;
      private Button home_back_picture;
	@Override
	protected void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);
	this.getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN);
    requestWindowFeature(Window.FEATURE_NO_TITLE);
    setTheme(android.R.style.Theme_Black_NoTitleBar_Fullscreen);

    getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
    getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN);
    EyeDeviceInfo deviceInfo = (EyeDeviceInfo) this.getIntent().getSerializableExtra("deviceInfo");
	this.setContentView(R.layout.remoteconfigs);
	this.getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN);
	
	current = getIntent().getStringExtra("current");
	relativeLayout1= (RelativeLayout)findViewById(R.id.relativeLayout1);
	
    final Bundle bundle = new Bundle();
    bundle.putSerializable("deviceInfo",deviceInfo);   
	relativeLayout1.setOnClickListener(new RelativeLayout.OnClickListener() {
		
		@Override
		public void onClick(View v) {
			// TODO Auto-generated method stub
			Intent intent1 = new Intent(RemoteConfigP.this,SysRemonteSetP.class);  
			intent1.putExtra("current",current);
		    intent1.putExtras(bundle);
			startActivity(intent1);
		}
	});
	relativeLayout2= (RelativeLayout)findViewById(R.id.relativeLayout2);
	relativeLayout2.setOnClickListener(new RelativeLayout.OnClickListener() {
		
		@Override
		public void onClick(View v) {
			// TODO Auto-generated method stub
			Intent intent2 = new Intent(RemoteConfigP.this,NetWorkPage.class);      
			intent2.putExtra("current",current);
		    intent2.putExtras(bundle);
			startActivity(intent2);
		}
	});
	relativeLayout3= (RelativeLayout)findViewById(R.id.relativeLayout3);
	relativeLayout3.setOnClickListener(new RelativeLayout.OnClickListener() {
		
		@Override
		public void onClick(View v) {
			// TODO Auto-generated method stub
			
		}
	});
//	home_back_picture = (Button)this.findViewById(R.id.home_back6);
//	home_back_picture.setOnClickListener(new Button.OnClickListener()
//			 {
//		
//		@Override
//		public void onClick(View v) {
//			// TODO Auto-generated method stub
//			Intent intent = new Intent (RemoteConfigP.this,ListActivity.class);
//	    	intent.putExtra("comefrom", GlobalUtil.fromLoad);
//			startActivity(intent);
//		}
//	});
	
	
	}
	
    @Override
	protected void onResume() {
        super.onResume();
		if(GlobalUtil.OVSIAlarmConfig){
			ActivityList activityList = new ActivityList();
			activityList.put(this, 0);
			}
    }
    @Override
	protected void onDestroy() {
        super.onDestroy();
		if(GlobalUtil.OVSIAlarmConfig){
			ActivityList activityList = new ActivityList();
			activityList.remove(this);
			}
    }
}
